﻿using System;

namespace Bootstrap5.Abstractions;

/// <summary>
/// Represents a css class for component or parameter that value has set.
/// </summary>
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field)]
public class CssClassAttribute : Attribute
{
    /// <summary>
    /// Initializes an instance of <see cref="CssClassAttribute"/> class by given name.
    /// </summary>
    /// <param name="name">The css class name.</param>
    public CssClassAttribute(string name)
    {
        Name = name;
    }

    /// <summary>
    /// Gets the css class name.
    /// </summary>
    public string Name { get;  }
    /// <summary>
    /// Gets or sets the order of css class name.
    /// </summary>
    public int Order { get; set; }
}
